/**
 * Copyright (c) 2016 Lenovo Group
 * All Rights Reserved.
 * 
 * Project Name:lmrp-base
 * Create Time: 2016年1月28日 下午2:12:17
 */
package com.lenovo.lmrp.api.constant;

/**
 * @author zhangzhenga
 *
 */
public enum TicketStatus {
    
    ALL(-1,"全部"),
    GRABBING(0,"待抢单"),
    ACCEPTING(1,"待接单"),
    INEXCUTION(2,"执行中"),
    FINISHED(3,"完成"),
    CLOSED(4,"已关单"),
    TOSITE(5,"场站"),
    REJECTED(6,"已退单"),
	BREAK(7,"快速完成");
    
    private int num;
    private String descr;
    
    private TicketStatus(int num,String descr){
        this.num = num;
        this.descr = descr;
    }
    
    public static TicketStatus get(int num){
        for (TicketStatus  ts: TicketStatus.values()) {
            if(ts.num == num) return ts;
        }
        return null;
    }

	public int getStatus() {
		return num;
	}
}
